home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 9572 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  994 b 

  1. Path: accursio.comune.bologna.it!usenet
  2. From: Enrico Persiani <vos0225@iperbole.bologna.it>
  3. Newsgroups: comp.lang.c
  4. Subject: Re: Converting to "FULL" ASCII
  5. Date: Mon, 11 Mar 1996 21:25:27 +0100
  6. Organization: Progetto Iperbole - Comune di Bologna - Italy
  7. Message-ID: <31448C37.2D38@iperbole.bologna.it>
  8. References: <4i0prp$tn6@lantana.singnet.com.sg>
  9. NNTP-Posting-Host: itiav.comune.bologna.it
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 2.0GoldB1 (Win95; I)
  14. CC: vos0225@iperbole.bologna.it
  15.  
  16. Charles Lai wrote:
  17. > Hi... Does anyone know how to convert an integer 0-255 to its extended
  18. > ASCII representation?
  19. > toascii only convert up to 127....try this:
  20.  
  21. unsigned char cExtAscii;
  22.  
  23. cExtAscii = (unsigned char) nMyIntNum; /* where nMyIntNum is an integer from 0 to 255 */
  24.  
  25. -- 
  26. Enrico Persiani
  27. Computer Science Student
  28.  
  29. e-mail:  vos0225@iperbole.bologna.it
  30. address: Via A. Saffi 6
  31.          Bologna (BO), 40131
  32.          ITALY
  33.